package org.example.text03;

/**
 * 姓名年龄抽象类，实现Role接口
 */

public abstract class NameRole implements Role{
    private String name;
    private int age;

    public NameRole(){

    }

    public NameRole(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
}
